package java46_oo4;

public class TestArr {

	public static void main(String[] args) {
		// boolean f[] = new boolean[10];
		// f[1] = true;
		// for (boolean b : f) {
		// System.out.println(b);
		// }
		Student[] s = new Student[10];

		s[0] = new Student();

		s[0].name = "张三";
		s[0].java = 99;
		Student s2 = new Student();
		s2.name = "张洋";
		s[1] = s2;
		for (Student s1 : s) {
			if (s1 != null)
				System.out.println(s1.name);
			else
				System.out.println(s1);
		}
		Student a2[] = { new Student(), new Student(), new Student(),
				new Student() };
	}

}
